<?php
/*
 * Squelette : fstdtweekly/folder.html
 * Date :      Fri, 07 Jul 2006 11:29:56 GMT
 * Compile :   Fri, 10 Nov 2006 20:38:02 GMT (0.03s)
 * Boucles :   _author, _article, _folder
 */ 
//
// <BOUCLE auteurs>
//
function BOUCLE_authorhtml_ebc30cf731b8ca82c8f976a916920eca(&$Cache, &$Pile, &$doublons, &$Numrows, $SP) {

	// REQUETE
	$result = spip_abstract_select(
		array("auteurs.id_auteur",
		"auteurs.nom"), # SELECT
		array("spip_auteurs_articles AS auteurs_articles1","spip_auteurs AS auteurs"), # FROM
		array("auteurs.id_auteur=auteurs_articles1.id_auteur",
		"(auteurs_articles1.id_article = '" . addslashes($Pile[$SP]['id_article']) . "')",
		"NOT(auteurs.statut='5poubelle')"), # WHERE
		'auteurs.id_auteur', # GROUP
		array(), # ORDER
		'', # LIMIT
		'', # sous
		'', # HAVING
		'auteurs', # table
		'_author', # boucle
		''); # serveur
	$t0 = "";
	$SP++;

	// RESULTATS
	while ($Pile[$SP] = @spip_abstract_fetch($result,"")) {

		$Cache['id_auteur'][$Pile[$SP]['id_auteur']] = 1; // invalideurs

		$t1 = ('
			<a href="author.php?id_auteur=' .
$Pile[$SP]['id_auteur'] .
'">' .
interdire_scripts(typo($Pile[$SP]['nom'])) .
'</a>
			');
		$t0 .= (($t1 && $t0) ? ', ' : '') . $t1;
	}

	@spip_abstract_free($result,'');
	return $t0;
}


//
// <BOUCLE articles>
//
function BOUCLE_articlehtml_ebc30cf731b8ca82c8f976a916920eca(&$Cache, &$Pile, &$doublons, &$Numrows, $SP) {
	$old_lang = $GLOBALS['spip_lang'];

	// REQUETE
	$result = spip_abstract_select(
		array("articles.id_article",
		"articles.titre",
		"articles.chapo",
		"articles.lang"), # SELECT
		array("spip_articles AS articles"), # FROM
		array("(articles.id_rubrique = '" . addslashes($Pile[$SP]['id_rubrique']) . "')",
		"articles.statut='publie'"), # WHERE
		'', # GROUP
		array('articles.date' . ' DESC'), # ORDER
		'', # LIMIT
		'', # sous
		'', # HAVING
		'articles', # table
		'_article', # boucle
		''); # serveur
	$t0 = "";
	$SP++;

	// RESULTATS
	while ($Pile[$SP] = @spip_abstract_fetch($result,"")) {

		$Cache['id_article'][$Pile[$SP]['id_article']] = 1; // invalideurs
		if (!$GLOBALS['forcer_lang'])
	 		$GLOBALS['spip_lang'] = ($x = $Pile[$SP]['lang']) ? $x : $old_lang;
		$t0 .= ('
		<p>
			<a href="article.php?id_article=' .
$Pile[$SP]['id_article'] .
'">' .
interdire_scripts(typo($Pile[$SP]['titre'])) .
'</a>
			' .
(($t1 = BOUCLE_authorhtml_ebc30cf731b8ca82c8f976a916920eca($Cache, $Pile, $doublons, $Numrows, $SP)) ?
			('
			-- 
			' . $t1 . '
			
			') :
			('')) .
'
			' .
(($t1 = interdire_scripts(traiter_raccourcis(nettoyer_chapo($Pile[$SP]['chapo'])))) ?
			('<br>' . $t1) :
			('')) .
'
		</p>
	');
	}

	$GLOBALS['spip_lang'] = $old_lang;
	@spip_abstract_free($result,'');
	return $t0;
}


//
// <BOUCLE rubriques>
//
function BOUCLE_folderhtml_ebc30cf731b8ca82c8f976a916920eca(&$Cache, &$Pile, &$doublons, &$Numrows, $SP) {
	$old_lang = $GLOBALS['spip_lang'];

	// REQUETE
	$result = spip_abstract_select(
		array("rubriques.id_rubrique",
		"rubriques.lang",
		"rubriques.titre",
		"rubriques.texte"), # SELECT
		array("spip_rubriques AS rubriques"), # FROM
		array("(rubriques.id_rubrique = '" . addslashes($Pile[$SP]['id_rubrique']) . "')",
		"rubriques.statut='publie'"), # WHERE
		'', # GROUP
		array(), # ORDER
		'', # LIMIT
		'', # sous
		'', # HAVING
		'rubriques', # table
		'_folder', # boucle
		''); # serveur
	$t0 = "";
	$SP++;

	// RESULTATS
	while ($Pile[$SP] = @spip_abstract_fetch($result,"")) {

		$Cache['id_rubrique'][$Pile[$SP]['id_rubrique']] = 1; // invalideurs
		if (!$GLOBALS['forcer_lang'])
	 		$GLOBALS['spip_lang'] = ($x = $Pile[$SP]['lang']) ? $x : $old_lang;
		$t0 .= ('
	<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
	<html dir="' .
lang_dir(($Pile[$SP]['lang'] ? $Pile[$SP]['lang'] : $GLOBALS['spip_lang']),'ltr','rtl') .
'" lang="' .
htmlentities($Pile[$SP]['lang'] ? $Pile[$SP]['lang'] : $GLOBALS['spip_lang']) .
'">
	<head>
	<title>' .
interdire_scripts(typo($Pile[$SP]['titre'])) .
' - ' .
interdire_scripts(typo(lire_meta('nom_site'))) .
'</title>
	' .

'<?php
	$contexte_inclus = array();
	include(\'fstdtweekly/header.php\');
?'.'>' .
'
	
	<div class="headertext">' .
interdire_scripts(typo($Pile[$SP]['titre'])) .
'</div>
	
	' .
(($t1 = interdire_scripts(traiter_raccourcis($Pile[$SP]['texte']))) ?
			('<p>' . $t1 . '</p>') :
			('')) .
'
	
	' .
BOUCLE_articlehtml_ebc30cf731b8ca82c8f976a916920eca($Cache, $Pile, $doublons, $Numrows, $SP) .
'
	
	' .

'<?php
	$contexte_inclus = array();
	include(\'fstdtweekly/footer.php\');
?'.'>' .
'
');
	}

	$GLOBALS['spip_lang'] = $old_lang;
	@spip_abstract_free($result,'');
	return $t0;
}



//
// Fonction principale du squelette fstdtweekly/folder.html
//
function html_ebc30cf731b8ca82c8f976a916920eca ($Cache, $Pile, $doublons=array(), $Numrows='', $SP=0) {
$t0 = (($t1 = BOUCLE_folderhtml_ebc30cf731b8ca82c8f976a916920eca($Cache, $Pile, $doublons, $Numrows, $SP)) ?
			($t1) :
			(('

	<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
	<html dir="' .
lang_dir(($Pile[0]['lang'] ? $Pile[0]['lang'] : $GLOBALS['spip_lang']),'ltr','rtl') .
'" lang="' .
htmlentities($Pile[0]['lang'] ? $Pile[0]['lang'] : $GLOBALS['spip_lang']) .
'">
	<head>
	<title>Folder Not Found - ' .
interdire_scripts(typo(lire_meta('nom_site'))) .
'</title>
	' .

'<?php
	$contexte_inclus = array();
	include(\'fstdtweekly/header.php\');
?'.'>' .
'
	Oops, you seem to have stumbled into a section of the site that doesn\'t exist yet. I recommend clicking the back button, lest ye be eaten by a grue.
	' .

'<?php
	$contexte_inclus = array();
	include(\'fstdtweekly/footer.php\');
?'.'>' .
'
')));

	return array(
		'texte' => $t0,
		'squelette' => 'html_ebc30cf731b8ca82c8f976a916920eca',
		'process_ins' => ((strpos($t0,'<'.'?')=== false) ? 'html' : 'php'),
		'invalideurs' => $Cache
	);
}

?>